﻿using Idea.Entity.Collections.Interface;
using Idea.UnitOfWork.Interface;

namespace Idea.Repository.Collections.Interface
{
    public interface ICollectionRepository : ICollectionQueryExecuter, IUnitOfWorkable
    {
        TCollection Find<TCollection>(string id)
            where TCollection : class, ICollectionEntity;

        TCollection Create<TCollection>(TCollection entity)
            where TCollection : class, ICollectionEntity;

        TCollection Update<TCollection>(TCollection entity)
            where TCollection : class, ICollectionEntity;

        void Delete<TCollection>(TCollection entity)
            where TCollection : class, ICollectionEntity;
    }
}
